package com.qianfeng.client_7001.client;


import com.qianfeng.client_7001.entity.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;


@FeignClient(value = "SEARCH-V1",fallbackFactory = SearchClientFallBackFactory.class)
public interface SearchClient {


    @RequestMapping("/search")
    String helloSearch();


    @RequestMapping("/s1/{id}")
    String s1(@PathVariable("id") Integer id);

    @RequestMapping("/s2")
    String s2(@RequestParam("id") Integer id, @RequestParam("name")String name);


    @RequestMapping("/s3")
    User s3(@RequestBody User user);


}
